<div class="title">
  <div class='content'>
    预订项目
  </div>
  <div class='tools'>
    <%= link_to '返回',
          order_items_order_url(@order_item.order),
          :remote => true,
          :method => :get
     %>
  </div>
</div>
<%= form_for @order_item, :as => :order_item,
     :url => update_spots_ordered_order_item_order_url(@order_item),
     :remote => true,
     :method => :post do |f|
 %> 
<div class='info'>        
  <table >
    <tr>
      <th>
        型号：
      </th>
      <td>
        <%= f.hidden_field :order_id %>
        <%= hidden_field_tag :furniture_style_id, params[:furniture_style_id] %>
        <%= @order_item.furnitures.first.furniture_style.full_name %>
      </td>
    </tr>
    <tr>
      <th>
        材质：
      </th>
      <td>
        <%= hidden_field_tag :material_id, params[:material_id] %>
        <%= @order_item.furnitures.first.material.full_name %>
      </td>
    </tr>
    <tr id='stored_furnitures'>
      <th>库存：</th>
      <td><%= render 'stored_furnitures.html' %></td>
    </tr>
    <tr>
      <th>
        备注：
      </th>
      <td >
        <%= f.text_area :remark, :rows => 5 %>
      </td>
    </tr>
    <tr>
      <td colspan='2' class='b'>
        <%= f.submit '现货预订', :class => 'bb spots_order' %>
        <%= link_to '返回',
              order_items_order_url(@order_item.order),
              :remote => true,
              :method => :get,              
              :class => :bb
         %> 
      </td>
    </tr>
  </table>    
</div>
<% end %>